package C;

import java.util.Locale;
import java.util.Scanner;

public class C51 {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int k = Integer.parseInt(sc.nextLine());
        String input = sc.nextLine();
        System.out.println(getResult(k,input));
    }
    public static String getResult(int k,String input) {
        int count = 0;
        int countk = 0;
        StringBuilder sb = new StringBuilder();
        for (int i = 0; i < input.length(); i++) {
            char c = input.charAt(i);
            if (count==0 && c !='-') {
                sb.append(c);
            } else if (count==0 && c=='-') {
                count++;
                sb.append('-');
                continue;
            } else if(count>0&&c=='-') {
                continue;
            } else {
                c = String.valueOf(c).toUpperCase().charAt(0);
                sb.append(c);
                countk = (countk+1)%k;
                if (countk==0&&i!=input.length()-1) {
                    sb.append('-');
                }
            }
        }
        return sb.toString();
    }
}
